import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '@/views/Home.vue'
import Login from '@/views/Login.vue'
import Tration from '@/views/Tration.vue'
import Personal from '@/views/Personal.vue'
import Editing from '@/views/Editing.vue'
import Concerns from '@/views/Concerns.vue'
import cheshi from '../views/cheshi.vue'

Vue.use(VueRouter)

const routes = [
  // 主页
  {
    path: '/',
    name: 'Home',
    component: Home,
  },
  // 登录页
  {
    path: '/login',
    name: 'Login',
    component: Login
  },
  // 注册页
  {
    path: '/tration',
    name: 'Tration',
    component: Tration
  },

  // 个人信息页
  {
    path: '/personal',
    name: 'Personal',
    component: Personal,
    meta: {
      auto: true
    }
  },
  // 编辑页
  {
    path: '/editing',
    name: 'editing',
    component: Editing,
    meta: {
      auto: true
    }
  },
  // 关注页
  {
    path: '/concerns',
    name: 'concerns',
    component: Concerns
  },
  //测试
  {
    path: '/cheshi',
    name: cheshi,
    component: cheshi
  }

]

const router = new VueRouter({
  routes
})

export default router
